package com.hsnn.medstgmini.base.std.model;

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Embeddable;


/**
 * StdDruginfoDetailLogId entity. @author MyEclipse Persistence Tools
 */
@Embeddable

public class StdDruginfoDetailLogId  implements java.io.Serializable {


    // Fields    

     private String drugId;
     private Short drugAttr;
     private Integer drugIndex;
     private String pharId;
     private Short patternType;
     private Short drugSource;
     private Short isLowprice;
     private Short isAgriculture;
     private Short isHealthcare;
     private String drugStdCode;
     private String drugStdcdRemark;
     private String remark;
     private Timestamp updDatetime;
     private String updUser;


    // Constructors

    /** default constructor */
    public StdDruginfoDetailLogId() {
    }

    
    /** full constructor */
    public StdDruginfoDetailLogId(String drugId, Short drugAttr, Integer drugIndex, String pharId, Short patternType, Short drugSource, Short isLowprice, Short isAgriculture, Short isHealthcare, String drugStdCode, String drugStdcdRemark, String remark, Timestamp updDatetime, String updUser) {
        this.drugId = drugId;
        this.drugAttr = drugAttr;
        this.drugIndex = drugIndex;
        this.pharId = pharId;
        this.patternType = patternType;
        this.drugSource = drugSource;
        this.isLowprice = isLowprice;
        this.isAgriculture = isAgriculture;
        this.isHealthcare = isHealthcare;
        this.drugStdCode = drugStdCode;
        this.drugStdcdRemark = drugStdcdRemark;
        this.remark = remark;
        this.updDatetime = updDatetime;
        this.updUser = updUser;
    }

   
    // Property accessors

    @Column(name="drug_id", length=36)

    public String getDrugId() {
        return this.drugId;
    }
    
    public void setDrugId(String drugId) {
        this.drugId = drugId;
    }

    @Column(name="drug_attr")

    public Short getDrugAttr() {
        return this.drugAttr;
    }
    
    public void setDrugAttr(Short drugAttr) {
        this.drugAttr = drugAttr;
    }

    @Column(name="drug_index")

    public Integer getDrugIndex() {
        return this.drugIndex;
    }
    
    public void setDrugIndex(Integer drugIndex) {
        this.drugIndex = drugIndex;
    }

    @Column(name="phar_id", length=36)

    public String getPharId() {
        return this.pharId;
    }
    
    public void setPharId(String pharId) {
        this.pharId = pharId;
    }

    @Column(name="pattern_type")

    public Short getPatternType() {
        return this.patternType;
    }
    
    public void setPatternType(Short patternType) {
        this.patternType = patternType;
    }

    @Column(name="drug_source")

    public Short getDrugSource() {
        return this.drugSource;
    }
    
    public void setDrugSource(Short drugSource) {
        this.drugSource = drugSource;
    }

    @Column(name="is_lowprice")

    public Short getIsLowprice() {
        return this.isLowprice;
    }
    
    public void setIsLowprice(Short isLowprice) {
        this.isLowprice = isLowprice;
    }

    @Column(name="is_agriculture")

    public Short getIsAgriculture() {
        return this.isAgriculture;
    }
    
    public void setIsAgriculture(Short isAgriculture) {
        this.isAgriculture = isAgriculture;
    }

    @Column(name="is_healthcare")

    public Short getIsHealthcare() {
        return this.isHealthcare;
    }
    
    public void setIsHealthcare(Short isHealthcare) {
        this.isHealthcare = isHealthcare;
    }

    @Column(name="drug_std_code", length=128)

    public String getDrugStdCode() {
        return this.drugStdCode;
    }
    
    public void setDrugStdCode(String drugStdCode) {
        this.drugStdCode = drugStdCode;
    }

    @Column(name="drug_stdcd_remark", length=1024)

    public String getDrugStdcdRemark() {
        return this.drugStdcdRemark;
    }
    
    public void setDrugStdcdRemark(String drugStdcdRemark) {
        this.drugStdcdRemark = drugStdcdRemark;
    }

    @Column(name="remark", length=4000)

    public String getRemark() {
        return this.remark;
    }
    
    public void setRemark(String remark) {
        this.remark = remark;
    }

    @Column(name="upd_datetime", length=19)

    public Timestamp getUpdDatetime() {
        return this.updDatetime;
    }
    
    public void setUpdDatetime(Timestamp updDatetime) {
        this.updDatetime = updDatetime;
    }

    @Column(name="upd_user", length=36)

    public String getUpdUser() {
        return this.updUser;
    }
    
    public void setUpdUser(String updUser) {
        this.updUser = updUser;
    }
   



   public boolean equals(Object other) {
         if ( (this == other ) ) return true;
		 if ( (other == null ) ) return false;
		 if ( !(other instanceof StdDruginfoDetailLogId) ) return false;
		 StdDruginfoDetailLogId castOther = ( StdDruginfoDetailLogId ) other; 
         
		 return ( (this.getDrugId()==castOther.getDrugId()) || ( this.getDrugId()!=null && castOther.getDrugId()!=null && this.getDrugId().equals(castOther.getDrugId()) ) )
 && ( (this.getDrugAttr()==castOther.getDrugAttr()) || ( this.getDrugAttr()!=null && castOther.getDrugAttr()!=null && this.getDrugAttr().equals(castOther.getDrugAttr()) ) )
 && ( (this.getDrugIndex()==castOther.getDrugIndex()) || ( this.getDrugIndex()!=null && castOther.getDrugIndex()!=null && this.getDrugIndex().equals(castOther.getDrugIndex()) ) )
 && ( (this.getPharId()==castOther.getPharId()) || ( this.getPharId()!=null && castOther.getPharId()!=null && this.getPharId().equals(castOther.getPharId()) ) )
 && ( (this.getPatternType()==castOther.getPatternType()) || ( this.getPatternType()!=null && castOther.getPatternType()!=null && this.getPatternType().equals(castOther.getPatternType()) ) )
 && ( (this.getDrugSource()==castOther.getDrugSource()) || ( this.getDrugSource()!=null && castOther.getDrugSource()!=null && this.getDrugSource().equals(castOther.getDrugSource()) ) )
 && ( (this.getIsLowprice()==castOther.getIsLowprice()) || ( this.getIsLowprice()!=null && castOther.getIsLowprice()!=null && this.getIsLowprice().equals(castOther.getIsLowprice()) ) )
 && ( (this.getIsAgriculture()==castOther.getIsAgriculture()) || ( this.getIsAgriculture()!=null && castOther.getIsAgriculture()!=null && this.getIsAgriculture().equals(castOther.getIsAgriculture()) ) )
 && ( (this.getIsHealthcare()==castOther.getIsHealthcare()) || ( this.getIsHealthcare()!=null && castOther.getIsHealthcare()!=null && this.getIsHealthcare().equals(castOther.getIsHealthcare()) ) )
 && ( (this.getDrugStdCode()==castOther.getDrugStdCode()) || ( this.getDrugStdCode()!=null && castOther.getDrugStdCode()!=null && this.getDrugStdCode().equals(castOther.getDrugStdCode()) ) )
 && ( (this.getDrugStdcdRemark()==castOther.getDrugStdcdRemark()) || ( this.getDrugStdcdRemark()!=null && castOther.getDrugStdcdRemark()!=null && this.getDrugStdcdRemark().equals(castOther.getDrugStdcdRemark()) ) )
 && ( (this.getRemark()==castOther.getRemark()) || ( this.getRemark()!=null && castOther.getRemark()!=null && this.getRemark().equals(castOther.getRemark()) ) )
 && ( (this.getUpdDatetime()==castOther.getUpdDatetime()) || ( this.getUpdDatetime()!=null && castOther.getUpdDatetime()!=null && this.getUpdDatetime().equals(castOther.getUpdDatetime()) ) )
 && ( (this.getUpdUser()==castOther.getUpdUser()) || ( this.getUpdUser()!=null && castOther.getUpdUser()!=null && this.getUpdUser().equals(castOther.getUpdUser()) ) );
   }
   
   public int hashCode() {
         int result = 17;
         
         result = 37 * result + ( getDrugId() == null ? 0 : this.getDrugId().hashCode() );
         result = 37 * result + ( getDrugAttr() == null ? 0 : this.getDrugAttr().hashCode() );
         result = 37 * result + ( getDrugIndex() == null ? 0 : this.getDrugIndex().hashCode() );
         result = 37 * result + ( getPharId() == null ? 0 : this.getPharId().hashCode() );
         result = 37 * result + ( getPatternType() == null ? 0 : this.getPatternType().hashCode() );
         result = 37 * result + ( getDrugSource() == null ? 0 : this.getDrugSource().hashCode() );
         result = 37 * result + ( getIsLowprice() == null ? 0 : this.getIsLowprice().hashCode() );
         result = 37 * result + ( getIsAgriculture() == null ? 0 : this.getIsAgriculture().hashCode() );
         result = 37 * result + ( getIsHealthcare() == null ? 0 : this.getIsHealthcare().hashCode() );
         result = 37 * result + ( getDrugStdCode() == null ? 0 : this.getDrugStdCode().hashCode() );
         result = 37 * result + ( getDrugStdcdRemark() == null ? 0 : this.getDrugStdcdRemark().hashCode() );
         result = 37 * result + ( getRemark() == null ? 0 : this.getRemark().hashCode() );
         result = 37 * result + ( getUpdDatetime() == null ? 0 : this.getUpdDatetime().hashCode() );
         result = 37 * result + ( getUpdUser() == null ? 0 : this.getUpdUser().hashCode() );
         return result;
   }   





}